package com.blockmeta.bbs.immodule.corebean;

import com.blockmeta.bbs.baselibrary.net.callback.BaseResponseCallBack;
import com.blockmeta.bbs.immodule.bean.databean.UserBean;
import com.blockmeta.bbs.immodule.dao.IMUserEntity;

import java.util.List;

public interface IUserDomainService {

    void getUser(long userID, boolean needUpdate, BaseResponseCallBack<String, IMUserEntity> callBack);

    void updateUserAvator(String mUserId, String avator);

    boolean isFriend(long userId);

    void addFriend(long user_id, BaseResponseCallBack callBack);

    void deleteFriend(long user_id);

    /**
     * 如果聊天消息中包含的用户信息和本地保存的信息不一致，就更新本地用户信息
     * @param fromId
     * @param userName
     * @param userAvator
     * @param userGroupId
     */
    void updateUserNameAndAvator(long fromId, String userName, String userAvator, int userGroupId);

    void addCustomerServiceUsers(List<UserBean> list);

    void getCustomerServiceList();

    /**
     * 查询我的好友分页
     * @param word
     * @param pageSize
     * @param page
     * @return
     */
    List<IMUserEntity> searchFriendPaged(String word, int pageSize, int page, String orderField, String orderType);

    /**
     * 查询我的圈子分页
     * @param word
     * @param pageSize
     * @param page
     * @return
     */
    List<IMUserEntity> searchCirclePaged(String word, int pageSize, int page, String orderField, String orderType);

    IMUserEntity getUser(long fromId, int type);

    List<IMUserEntity> getBookListFriends(long uidInt);

    boolean isFriend(long uidInt, long id);

    void changeUserRemarkName(String trim, long friendId);

    IMUserEntity addAndUpdateUser(long uidInt, IMUserEntity imUserEntity);

}
